<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
	xmlns:h="http://java.sun.com/jsf/html"
	xmlns:t="http://myfaces.apache.org/tomahawk"
	xmlns:f="http://java.sun.com/jsf/core">
<f:view contentType="text/html">
	<h:form id="WMTreeForm">
		<!-- Expand/Collapse Handled By Server -->
		<t:tree2 id="serverTree" value="#{menuBean.treeModel}" var="node"
			varNodeToggler="t" clientSideToggle="false" preserveToggle="true">
			<f:facet name="nonActionNode">
				<h:panelGroup>
					<t:graphicImage value="#{node.iconClosed}"
						styleClass="borderLessImage" rendered="#{!t.nodeExpanded}"
						title="#{node.toolTip}" alt="#{node.toolTip}" />
					<t:graphicImage value="#{node.iconOpened}"
						rendered="#{t.nodeExpanded}" styleClass="borderLessImage"
						title="#{node.toolTip}" alt="#{node.toolTip}" />
					<h:outputText value="#{node.description}" styleClass="nodeFolder"
						escape="false" />
				</h:panelGroup>
			</f:facet>
			<f:facet name="inactiveNode">
				<h:panelGroup>
					<t:graphicImage value="#{node.iconClosed}"
						styleClass="borderLessImage" rendered="#{!t.nodeExpanded}"
						title="#{node.toolTip}" alt="#{node.toolTip}" />
					<t:graphicImage value="#{node.iconOpened}"
						rendered="#{t.nodeExpanded}" styleClass="borderLessImage"
						title="#{node.toolTip}" alt="#{node.toolTip}" />
					<h:outputText value="#{node.description}" styleClass="nodeFolder"
						escape="false" />
				</h:panelGroup>
			</f:facet>

			<f:facet name="actionList">
				<h:panelGroup>
					<t:graphicImage value="#{node.iconOpened}"
						styleClass="borderLessImage" id="imagen" alt="#{node.toolTip}"
						title="#{node.toolTip}" />
					<h:commandLink action="#{menuBean.cambiarMenu}"
						title="#{node.toolTip}" value="#{node.descripcion}">
						<f:param name="bean" value="#{node.bean}" />
						<f:param name="pagina" value="#{node.pagina}" />
					</h:commandLink>
				</h:panelGroup>
			</f:facet>

		</t:tree2>
	</h:form>
</f:view>
</html>